package com.ruoyi.exam_syllabus.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.exam_syllabus.mapper.TsExamDetailsMapper;
import com.ruoyi.exam_syllabus.domain.TsExamDetails;
import com.ruoyi.exam_syllabus.service.ITsExamDetailsService;

/**
 * 考试详情Service业务层处理
 *
 * @author hongyi
 * @date 2023-12-25
 */
@Service
public class TsExamDetailsServiceImpl implements ITsExamDetailsService
{
    @Autowired
    private TsExamDetailsMapper tsExamDetailsMapper;

    /**
     * 查询考试详情
     *
     * @param examDetailsId 考试详情主键
     * @return 考试详情
     */
    @Override
    public TsExamDetails selectTsExamDetailsByExamDetailsId(Long examDetailsId)
    {
        return tsExamDetailsMapper.selectTsExamDetailsByExamDetailsId(examDetailsId);
    }


    @Override
    public TsExamDetails getTsExamDetailsByExamDetailsPints(Long points) {
        return tsExamDetailsMapper.getTsExamDetailsByExamDetailsPints(points);
    }

    /**
     * 查询考试详情列表
     *
     * @param tsExamDetails 考试详情
     * @return 考试详情
     */
    @Override
    public List<TsExamDetails> selectTsExamDetailsList(TsExamDetails tsExamDetails)
    {
        return tsExamDetailsMapper.selectTsExamDetailsList(tsExamDetails);
    }

    /**
     * 新增考试详情
     *
     * @param tsExamDetails 考试详情
     * @return 结果
     */
    @Override
    public int insertTsExamDetails(TsExamDetails tsExamDetails)
    {
        return tsExamDetailsMapper.insertTsExamDetails(tsExamDetails);
    }

    /**
     * 修改考试详情
     *
     * @param tsExamDetails 考试详情
     * @return 结果
     */
    @Override
    public int updateTsExamDetails(TsExamDetails tsExamDetails)
    {
        return tsExamDetailsMapper.updateTsExamDetails(tsExamDetails);
    }

    /**
     * 批量删除考试详情
     *
     * @param examDetailsIds 需要删除的考试详情主键
     * @return 结果
     */
    @Override
    public int deleteTsExamDetailsByExamDetailsIds(Long[] examDetailsIds)
    {
        return tsExamDetailsMapper.deleteTsExamDetailsByExamDetailsIds(examDetailsIds);
    }

    /**
     * 删除考试详情信息
     *
     * @param examDetailsId 考试详情主键
     * @return 结果
     */
    @Override
    public int deleteTsExamDetailsByExamDetailsId(Long examDetailsId)
    {
        return tsExamDetailsMapper.deleteTsExamDetailsByExamDetailsId(examDetailsId);
    }
}
